<?php
namespace Home\Controller;
use Think\Controller;

use Weixin\Wechat;
use Weixin\WechatAuth;

class PrefeController extends CommonController {
     public function prefe(){
    	$prefe=M('user_prefe');
        $userid=session('userid');
        $res=$prefe->query("select u.time ,p.name,p.type,p.buss,p.context,p.image,p.end_time from kl_user_prefe u,kl_prefe p where u.prefe=p.id and u.user='{$userid}'");
            //dump($res);
        $this->assign('res',$res);
        $this->display('prefe');
    }
}